import logo from './logo.svg';
import './App.css';
import React, { useState } from 'react';
import { Button, Modal } from 'antd';

function App() {
  const [isModelState, setIsModelState] = useState(false);
  const showModal = () => {
    setIsModelState(true)
  }

  const handleOk = () => {
    setIsModelState(false)
  }

  const handleCancel = () => {
    setIsModelState(false);
  }

  return (
    <>
      <Button type="primary" onClick={showModal}>Open Modal</Button>
      <Modal title="基本弹窗" open={isModelState} onOk={handleOk} onCancel={handleCancel}>
        <p>Some Contents</p>
        <p>Some Contents</p>
        <p>Some Contents</p>
      </Modal>
    </>
  );
}

export default App;
